Display any "g_unicode_isgraph()" char literally, not just latin1.
authorOwen Taylor <otaylor@redhat.com>
Tue, 26 Feb 2002 23:46:23 +0000 (23:46 +0000)
committerOwen Taylor <otaylor@src.gnome.org>
Tue, 26 Feb 2002 23:46:23 +0000 (23:46 +0000)
Tue Feb 26 18:38:17 2002  Owen Taylor  <otaylor@redhat.com>

* gtk/gtkaccellabel.c (gtk_accel_label_refetch):
Display any "g_unicode_isgraph()" char literally,
not just latin1. (#65679)

ChangeLog
ChangeLog.pre-2-0
ChangeLog.pre-2-10
ChangeLog.pre-2-2
ChangeLog.pre-2-4
ChangeLog.pre-2-6
ChangeLog.pre-2-8
gtk/gtkaccellabel.c

index 6d21017cd7db778f374fe07a9ede9a3020c127c0..8dd432278c992f903eb56588a0a762b483e9a643 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,8 +1,14 @@
+Tue Feb 26 18:38:17 2002  Owen Taylor  <otaylor@redhat.com>
+
+       * gtk/gtkaccellabel.c (gtk_accel_label_refetch): 
+       Display any "g_unicode_isgraph()" char literally,
+       not just latin1. (#65679)
+
 Tue Feb 26 18:01:10 2002  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/gtkwidget.c (gtk_widget_grab_focus): Don't
-       to focus insensitive widgets. (#68203)
-
+       focus insensitive widgets. (#68203)
+       
        * gtk/gtkentry.c (gtk_entry_state_changed): Clear any
        current selection if we become insensitive. (#68203)
 
index 6d21017cd7db778f374fe07a9ede9a3020c127c0..8dd432278c992f903eb56588a0a762b483e9a643 100644 (file)
@@ -1,8 +1,14 @@
+Tue Feb 26 18:38:17 2002  Owen Taylor  <otaylor@redhat.com>
+
+       * gtk/gtkaccellabel.c (gtk_accel_label_refetch): 
+       Display any "g_unicode_isgraph()" char literally,
+       not just latin1. (#65679)
+
 Tue Feb 26 18:01:10 2002  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/gtkwidget.c (gtk_widget_grab_focus): Don't
-       to focus insensitive widgets. (#68203)
-
+       focus insensitive widgets. (#68203)
+       
        * gtk/gtkentry.c (gtk_entry_state_changed): Clear any
        current selection if we become insensitive. (#68203)
 
index 6d21017cd7db778f374fe07a9ede9a3020c127c0..8dd432278c992f903eb56588a0a762b483e9a643 100644 (file)
@@ -1,8 +1,14 @@
+Tue Feb 26 18:38:17 2002  Owen Taylor  <otaylor@redhat.com>
+
+       * gtk/gtkaccellabel.c (gtk_accel_label_refetch): 
+       Display any "g_unicode_isgraph()" char literally,
+       not just latin1. (#65679)
+
 Tue Feb 26 18:01:10 2002  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/gtkwidget.c (gtk_widget_grab_focus): Don't
-       to focus insensitive widgets. (#68203)
-
+       focus insensitive widgets. (#68203)
+       
        * gtk/gtkentry.c (gtk_entry_state_changed): Clear any
        current selection if we become insensitive. (#68203)
 
index 6d21017cd7db778f374fe07a9ede9a3020c127c0..8dd432278c992f903eb56588a0a762b483e9a643 100644 (file)
@@ -1,8 +1,14 @@
+Tue Feb 26 18:38:17 2002  Owen Taylor  <otaylor@redhat.com>
+
+       * gtk/gtkaccellabel.c (gtk_accel_label_refetch): 
+       Display any "g_unicode_isgraph()" char literally,
+       not just latin1. (#65679)
+
 Tue Feb 26 18:01:10 2002  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/gtkwidget.c (gtk_widget_grab_focus): Don't
-       to focus insensitive widgets. (#68203)
-
+       focus insensitive widgets. (#68203)
+       
        * gtk/gtkentry.c (gtk_entry_state_changed): Clear any
        current selection if we become insensitive. (#68203)
 
index 6d21017cd7db778f374fe07a9ede9a3020c127c0..8dd432278c992f903eb56588a0a762b483e9a643 100644 (file)
@@ -1,8 +1,14 @@
+Tue Feb 26 18:38:17 2002  Owen Taylor  <otaylor@redhat.com>
+
+       * gtk/gtkaccellabel.c (gtk_accel_label_refetch): 
+       Display any "g_unicode_isgraph()" char literally,
+       not just latin1. (#65679)
+
 Tue Feb 26 18:01:10 2002  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/gtkwidget.c (gtk_widget_grab_focus): Don't
-       to focus insensitive widgets. (#68203)
-
+       focus insensitive widgets. (#68203)
+       
        * gtk/gtkentry.c (gtk_entry_state_changed): Clear any
        current selection if we become insensitive. (#68203)
 
index 6d21017cd7db778f374fe07a9ede9a3020c127c0..8dd432278c992f903eb56588a0a762b483e9a643 100644 (file)
@@ -1,8 +1,14 @@
+Tue Feb 26 18:38:17 2002  Owen Taylor  <otaylor@redhat.com>
+
+       * gtk/gtkaccellabel.c (gtk_accel_label_refetch): 
+       Display any "g_unicode_isgraph()" char literally,
+       not just latin1. (#65679)
+
 Tue Feb 26 18:01:10 2002  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/gtkwidget.c (gtk_widget_grab_focus): Don't
-       to focus insensitive widgets. (#68203)
-
+       focus insensitive widgets. (#68203)
+       
        * gtk/gtkentry.c (gtk_entry_state_changed): Clear any
        current selection if we become insensitive. (#68203)
 
index 6d21017cd7db778f374fe07a9ede9a3020c127c0..8dd432278c992f903eb56588a0a762b483e9a643 100644 (file)
@@ -1,8 +1,14 @@
+Tue Feb 26 18:38:17 2002  Owen Taylor  <otaylor@redhat.com>
+
+       * gtk/gtkaccellabel.c (gtk_accel_label_refetch): 
+       Display any "g_unicode_isgraph()" char literally,
+       not just latin1. (#65679)
+
 Tue Feb 26 18:01:10 2002  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/gtkwidget.c (gtk_widget_grab_focus): Don't
-       to focus insensitive widgets. (#68203)
-
+       focus insensitive widgets. (#68203)
+       
        * gtk/gtkentry.c (gtk_entry_state_changed): Clear any
        current selection if we become insensitive. (#68203)
 
index 98c6a9961043c0efa1f42d4ee777edbfdfb6d5bf..c5d1b87167d998f83cca7bc957e8c7be762d1b0b 100644 (file)
@@ -492,6 +492,7 @@ gtk_accel_label_refetch (GtkAccelLabel *accel_label)
        {
          GString *gstring;
          gboolean seen_mod = FALSE;
+         gunichar ch;
          
          gstring = g_string_new (accel_label->accel_string);
          g_string_append (gstring, gstring->len ? class->accel_seperator : "   ");
@@ -517,12 +518,12 @@ gtk_accel_label_refetch (GtkAccelLabel *accel_label)
            }
          if (seen_mod)
            g_string_append (gstring, class->mod_separator);
-         if (key->accel_key < 0x80 ||
-             (key->accel_key > 0x80 &&
-              key->accel_key <= 0xff &&
-              class->latin1_to_char))
+
+         ch = gdk_keyval_to_unicode (key->accel_key);
+         if (ch && (g_unichar_isgraph (ch) || ch == ' ') &&
+             (ch < 0x80 || class->latin1_to_char))
            {
-             switch (key->accel_key)
+             switch (ch)
                {
                case ' ':
                  g_string_append (gstring, "Space");
@@ -531,7 +532,7 @@ gtk_accel_label_refetch (GtkAccelLabel *accel_label)
                  g_string_append (gstring, "Backslash");
                  break;
                default:
-                 g_string_append_unichar (gstring, g_unichar_toupper (key->accel_key));
+                 g_string_append_unichar (gstring, g_unichar_toupper (ch));
                  break;
                }
            }